<template>
	<view class="content">
		<nav-header bgColor="bg-custom-color" :isBack="true">
			<block slot="content">{{$t('usdtExtract')}}</block>
		</nav-header>


		<view class="cu-list menu card-menu margin-top wallet">
			<view class="cu-item " @click="$common.toPage('../index/index')">
				<view class="content et-content">
					<text class="text-grey et-text lc1-1 bg-color">USDT</text>
					<text class="text-grey et-text text-color">{{$t('balance')}}</text>
					<text class="text-grey et-text text-color">{{userInfo.biUsdt}}</text>
				</view>
			</view>
		</view>

		<view class="padding" style="display: flex;">
			<text class="bg-et thisBtn" @tap="tibi">{{$t('extract')}}</text>
			<text class="bg-et thisBtn" @click="$common.toPage('../wallet/wallet_usdt_record')">{{$t('record')}}</text>
		</view>

		<nav-bottom showIndex='2'></nav-bottom>
	</view>


</template>

<script>
	var t
	export default {
		data() {
			return {
				userInfo: null,
			}
		},
		onLoad() {
			t = this
			this.$i18n.locale = t.$common.localRead("local")
			t.userInfo = $common.getUser()
			if (!t.userInfo) {
				$common.notLoginUser()
			}

			console.info(t.userInfo)
		},
		methods: {
			tibi() {
				if (!t.userInfo.usdtAddr) {
					t.$common.showToast('USDT地址未绑定')
					setTimeout(function() {
						t.$common.toPage('../home/bind_usdt')
					}, 1500)
					return
				}
				t.$common.toPage('../wallet/wallet_usdt_from')
			}
		}
	}
</script>

<style>
	.thisBtn {
		flex: 1;
		padding: 10px;
		text-align: center;
		margin: 0 15px;
		border-radius: 10px;
	}

	.wallet .cu-item:after {
		border-bottom: 0px solid #ddd;
	}

	.wallet .cu-item {
		background-color: #121E2E;
	}

	.lc2-son-par {
		display: flex;
		height: 30px;
		line-height: 30px;
	}

	.lc2-son1-text {
		color: #5C7392;
		flex: 1;
		text-align: center;
	}

	.lc2-son2-text {
		flex: 1;
		text-align: center;
	}

	.cu-list.card-menu {
		overflow: hidden;
		margin-right: 0px;
		margin-left: 0px;
		border-radius: 0px;
	}

	.et-content {
		display: flex;
	}

	.et-text {
		flex: 1;
	}

	.lc1 {
		height: 60px;
		line-height: 60px;
		display: flex;
	}

	.lc1-box {
		/* display: inline-table; */
		flex: 1;
	}

	.lc1-1 {
		margin-left: 10px;
		font-weight: bold;
	}

	/* 
	.arrow {
		position: absolute;
		top: 0;
		right: 16px;
		bottom: 0;
		display: block;
		margin: auto;
		width: 16px;
		height: 16px;
		color: var(--grey);
		content: "\E6A3";
		text-align: center;
		font-size: 18px;
		font-family: cuIcon;
		line-height: 16px;
	} */
</style>
